# coding=utf-8

import web
from web import form

make_form = form.Form(
    
    # 猫优名
    form.Textbox('name'
        , form.regexp(r'^.{1,30}$', '请输入猫优名（最多30个字）')
        , description = '猫优名'
        , Class = 'form1'
        , style = 'width:25em'
        , autocomplete = 'off'
        , maxlength = '30'),

    # 猫优博客地址
    form.Textbox('url'
        , form.regexp(r'^[\w\-\.]{1,255}$', '请输入您推荐猫优的博客地址（最多255个字符）')
        , description = '博客地址'
        , Class = 'form1'
        , style = 'width: 25em'
        , autocomplete = 'off'
        , maxlength = '255'),

    # 猫优擅长领域
    form.Textarea('fields'
        , form.regexp(r'^[\s\S]{1,256}$', '请输入您推荐猫优擅长的领域')
        , description = '擅长领域'
        , Class = 'form1'
        , rows = '6'
        , style = 'width: 25em'),

)
